55c37d25ec7be26073b73a5ecf554b8f764d15bd,src/main/java/co/kepler/fastcraftplus/recipes/CraftingListener.java,CraftingListener,onPrepareItemCraft,#PrepareItemCraftEvent#,19
Before Change
@EventHandler
public void onPrepareItemCraft(PrepareItemCraftEvent e) {
for (CustomRecipe recipe : FastCraft.recipes().getRecipes()) { // TODO Hash for efficiency
if (!RecipeUtil.areEqual(recipe.getRecipe(), e.getRecipe())) continue;
if (recipe.matchesMatrix(e.getInventory().getMatrix())) {
e.getInventory().setResult(recipe.getDisplayResult());
} else {
After Change
@EventHandler
public void onPrepareItemCraft(PrepareItemCraftEvent e) {
CustomRecipe recipe = FastCraft.recipes().getRecipe(e.getRecipe());
if (recipe == null) return;
boolean matches = recipe.matchesMatrix(e.getInventory().getMatrix());
e.getInventory().setResult(matches ? recipe.getDisplayResult() : null);
}